package cn.kai.config;

import cn.kai.process.flow.core.FlowEnginLFU;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;

import javax.annotation.Resource;

/**
 Author: cKnight
 Date: 2025/2/7
 */
@Configuration
@Slf4j
public class BeanConfig {

    @Resource
    private ThreadPoolTaskExecutor threadPoolTaskExecutor;

    @Bean(value = "flowEnginLFU",initMethod = "init")
    public FlowEnginLFU getFlowEnginLFU (){
        return new FlowEnginLFU(500,threadPoolTaskExecutor);
    }
}
